package com.wing.product.model.request;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.wing.mybatis.common.BaseEntity;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.time.LocalDateTime;
import java.util.Date;
import java.util.List;

/**
 * 托管订单（入库）
 */
@Schema(description="托管订单（入库）")
@Data
@EqualsAndHashCode(callSuper=true)
@TableName(value = "warehouse_order")
public class WarehouseTransferOrderForm extends BaseEntity {
    @TableField("transfer_code")
    @Schema(description = "过户订单编号")
    private String transferCode;

    @TableField("seller_customer_id")
    @Schema(description = "出售方客户id")
    private Long sellerCustomerId;

    @TableField("buyer_customer_id")
    @Schema(description = "购买方客户id")
    private Long buyerCustomerId;

    @TableField("transfer_status")
    @Schema(description = "订单状态 0 待确认，1 确认过户（管理员操作）")
    private Integer transferStatus;

    @TableField("seller_confirm")
    @Schema(description = "出售方确认")
    private Integer sellerConfirm;

    @TableField("buyer_confirm")
    @Schema(description = "购买方确认")
    private Integer buyerConfirm;

    @TableField("seller_confirm_time")
    @Schema(description = "出售方确认时间")
    private LocalDateTime sellerConfirmTime;

    @TableField("buyerconfirm_time")
    @Schema(description = "购买方确认时间")
    private LocalDateTime buyerConfirmTime;

    @TableField("transfer_time")
    @Schema(description = "过户时间")
    private LocalDateTime transferTime;

    @TableField("source")
    @Schema(description = "数据来源")
    private Integer source;
    private List<WarehouseTransferOrderDetailForm> warehouseTransferOrderDetail;

    private Long sellerCustomerUser;
    private Long buyerCustomerUser;
    private String sellerCustomerPhone;
    private String buyerCustomerPhone;


    public interface Add{}
    public interface Update{}

    @TableField("handover_time")
    @Schema(description = "交割日期")
    private Date handoverTime;

    private String orderCode;

}